Node-RED block in Snap4City Microservice library node-red-contrib-snap4city-developer is "notificator-last-events">

It allows to request the last events that have been detected by the notifier. It is possible to choose the interval to check for new events.

Inputs

A JSON with these parameters:
dashboard string
The name of the dashboard where the event being notified was created
Widget string
The name of the widget where the event being notified was created
Event string
The name of the event to be observed with this node
Check Every number
Time interval that indicates when the presence of the event is re-checked (indicated in seconds)

Outputs

Returns an array containing the last events that have been detected by the notifier

Details

The node can receive a JSON with the parameters described in the Inputs section and with them generate the output JSON. If the values are not present in the input JSON, these are read by those in the configuration. If they are not present in either part, an error is generated for the necessary parameters.